package app.domain.orderBook;

import app.domain.order.Order;


public class BuyOrderBook extends OrderBook {

	@Override
	public void add(Order order) {		
		for (int j = 0; j < orderBook.size(); j++) {
			if(order.getPrice() > orderBook.get(j).getPrice()) {
				orderBook.add(j, order);
				break;
			}
		}
		orderBook.add(order);
	}

}
